<%@ taglib prefix="s" uri="/struts-tags" %>
<%--
  Created by IntelliJ IDEA.
  User: 高金磊
  Date: 2021/4/16
  Time: 14:53
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
    <title></title>
    <link rel="icon" href="<%=basePath%>favicon.ico" type="image/ico">
    <link href="<%=basePath%>css/bootstrap.min.css" rel="stylesheet">
    <link href="<%=basePath%>css/fonts.css" rel="stylesheet">
    <link href="<%=basePath%>css/style.css" rel="stylesheet">
</head>
<body>
<button class="btn btn-link" onclick="window.history.back()">返回上一级</button>
<br>
<span style="font-size: 15px; color: red"> <s:actionerror/></span>
<span style="font-size: 15px; color: #24bb10"> <s:actionmessage/></span>
<%--<s:form action="ShowInfoManage"  method="POST" enctype="multipart/form-data">--%>
    <%--<s:iterator value="#request.userinfoEntity" var="user">--%>
        <%--<input name="modify_id" type="hidden" value=<s:property value="#request.userinfoEntity.id"/>><br>--%>
        <%--<span>用户名：</span><br>--%>
        <%--<span><input name="username" value=<s:property value="#request.userinfoEntity.username"/>></span><br>--%>
        <%--<span>姓名：</span><br>--%>
        <%--<span><input name="name" value=<s:property value="#request.userinfoEntity.name"/>></span><br>--%>
        <%--<span>手机号</span><br>--%>
        <%--<span><input name="phone" value=<s:property value="#request.userinfoEntity.phone"/>></span><br>--%>
        <%--<span>年龄</span><br>--%>
        <%--<span><input name="age"  value=<s:property value="#request.userinfoEntity.age"/>></span><br>--%>
        <%--<span>密码</span><br>--%>
        <%--<span><input name="password"  value=<s:property value="#request.userinfoEntity.password"/>></span><br>--%>
        <%--<span style="font-size: 15px; color: red"> <s:actionerror/></span><br><br><br>--%>
        <%--<span style="font-size: 13px; color: red"> <%=request.getSession().getAttribute("message")%> </span><br><br><br>--%>
        <%--<input type="submit" value="提交" formaction="UpdateUserInfo"/>--%>
        <%--<input type="submit" value="删除" formaction="ShowInfoManage_Del"/>--%>
    <%--</s:iterator>--%>
<%--</s:form>--%>

<s:form action="AltUserInfo" method="get" >
<div class="col-md-6">
    <div class="card">
        <div class="card-header"><h4>用户信息修改</h4></div>
        <input name="modify_id" type="hidden" value=<s:property value="#request.userinfoEntity.id"/>>
        <div class="card-body">

            <div class="form-group">
                <label for="example-nf-11">ID</label>
                <input class="form-control" disabled="disabled" type="text" id="example-nf-11" value=<s:property value="#request.userinfoEntity.id"/> >
            </div>
                <div class="form-group">
                    <label for="example-nf-1">用户名</label>
                    <input class="form-control" type="text" id="example-nf-1" name="username" value=<s:property value="#request.userinfoEntity.username"/> >
                </div>
                <div class="form-group">
                    <label for="example-nf-2">姓名</label>
                    <input class="form-control" type="text" id="example-nf-2" name="name" value=<s:property value="#request.userinfoEntity.name"/>>
                </div>
                <div class="form-group">
                    <label for="example-nf-3">手机号</label>
                    <input class="form-control" type="tel" id="example-nf-3"  name="phone" value=<s:property value="#request.userinfoEntity.phone"/>>
                </div>
                <div class="form-group">
                    <label for="example-nf-4">年龄</label>
                    <input class="form-control" type="number" id="example-nf-4" name="age"  value=<s:property value="#request.userinfoEntity.age"/>>
                </div>
                <div class="form-group">
                    <label for="example-nf-5">密码</label>
                    <input class="form-control" type="password" id="example-nf-5" name="password"  value=<s:property value="#request.userinfoEntity.password"/>>
                </div>
                <div>
                    最近一次登录:<s:property value="#request.userinfoEntity.FormateRegisteTime()"/><br>
                    注册时间:<s:property value="#request.userinfoEntity.FormateRegisteTime()"/><br>
                    <%--<span style="font-size: 13px; color: red"> <%=request.getSession().getAttribute("message")==null?"":request.getSession().getAttribute("message")%> </span><br><br><br>--%>
                    <%--<input type="submit" value="提交" formaction="UpdateUserInfo"/>--%>
                    <%--<input type="submit" value="删除" formaction="ShowInfoManage_Del"/>--%>
                </div>
                <div class="form-group">
                    <button class="btn btn-label btn-primary" type="submit" formaction="UpdateUserInfo"><label><i class="ftsucai-gou-2"></i></label> 确认提交</button>
                    <button class="btn btn-label btn-danger" type="submit" formaction="ShowInfoManage_Del" >
                        <label><i class="ftsucai-del-1"></i></label>
                        删除
                    </button>
                </div>


        </div>
    </div>
    <div class="col-md-12">
        <div class="card">

            <div class="container-fluid"  style="margin-bottom:90px;" >

                <div class="row" style="margin-top:15px;">
                    <div class="col-lg-12">
                        <div class="card">
                            <div class="card-header"><h4>用户资料变更记录</h4></div>
                            <div class="card-body" style="max-height: 450px;overflow-y: auto">
                                <table class="table table-striped table-hover">
                                    <thead>
                                    <tr>

                                    </tr>
                                    </thead>
                                    <tbody>
                                    <s:iterator value="#request.User_userLogEntities" var="data">
                                        <tr>
                                            <td> <s:property value="#data.BuildLog()" /></td>
                                        </tr>

                                    </s:iterator>
                                    </tbody>
                                </table>
                            </div>

                        </div>
                    </div>
                </div>
            </div>

        </div>
        <br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br>
    </div>
</div>
<div class="col-md-6">
    <div class="card">

    <div class="container-fluid" style="margin-bottom:90px;">

        <div class="row" style="margin-top:15px;">
            <div class="col-lg-12">
                <div class="card">
                    <div class="card-header"><h4>用户近期登录记录</h4></div>
                    <div class="card-body" style="max-height: 1200px;overflow-y: auto">
                        <table class="table table-striped table-hover">
                            <thead>
                            <tr>
                            </tr>
                            </thead>
                            <tbody>
                            <s:iterator value="#request.userLogEntities" var="data">
                                <tr>
                                    <td> <s:property value="#data.BuildLog()" /></td>
                                </tr>

                            </s:iterator>
                            </tbody>
                        </table>
                        </div>

                    </div>
                </div>
            </div>
        </div>

    </div>
    <br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br>
</div>

</s:form>


    <script type="text/javascript" src="<%=basePath%>js/jquery.min.js"></script>
    <script type="text/javascript" src="<%=basePath%>js/bootstrap.js"></script>
    <script type="text/javascript" src="<%=basePath%>js/perfect-scrollbar.min.js"></script>
    <script type="text/javascript" src="<%=basePath%>js/main.min.js"></script>
    <script type="text/javascript">
        $(function(){
            $('.search-bar .dropdown-menu a').click(function() {
                var field = $(this).data('field') || '';
                $('#search-field').val(field);
                $('#search-btn').html($(this).text() + ' <span class="caret"></span>');
            });
        });
    </script>
</body>
</html>
